// 定时任务管理
import axios from "@/request/axios";

// 新增
export function jobManageAdd(params: any) {
  return axios({
    url: "/job/jobManage/add",
    method:"POST",
    data: params,
  });
}

// 修改
export function jobManageEdit(params: any) {
  return axios({
    url: "/job/jobManage/edit",
    method:"POST",
    data: params,
  });
}

// 获取详情
export function getJobManageById(id: any) {
  return axios({
    url: "/job/jobManage/detail",
    method:"POST",
    data: { id }
  });
}

// 查询（分页）
export function jobManageQuery(params: any) {
  return axios({
    url: "/job/jobManage/query",
    method:"POST",
    data: params,
  });
}

// 删除
export function jobManageDel(ids: any) {
  return axios({
    url: "/job/jobManage/del",
    method:"POST",
    data: ids,
  });
}

// 修改状态
export function jobManageChangeStatus(params: any) {
  return axios({
    url: "/job/jobManage/changeStatus",
    method:"POST",
    data: params,
  });
}

// 立即执行
export function jobManageRun(id: any) {
  return axios({
    url: "/job/jobManage/run",
    method:"POST",
    data: { id },
  });
}